using System.ComponentModel.DataAnnotations.Schema;
using System.Data.Entity.ModelConfiguration; using Sispe.Entities;

namespace Sispe.Repository.Mapping
{
    public class ESTADO_CIVILMap : EntityTypeConfiguration<ESTADO_CIVIL>
    {
        public ESTADO_CIVILMap()
        {
            // Primary Key
            this.HasKey(t => t.IdEstadoCivil);

            // Properties
            this.Property(t => t.Descripcion)
                .IsRequired()
                .HasMaxLength(50);

            // Table & Column Mappings
            this.ToTable("ESTADO_CIVIL");
            this.Property(t => t.IdEstadoCivil).HasColumnName("IdEstadoCivil");
            this.Property(t => t.Descripcion).HasColumnName("Descripcion");
        }
    }
}
